<?php
/**
 * Slince music finder library
 * @author Tao <taosikai@yeah.net>
 */
namespace Slince\MusicFinder\Entity;

class Song
{
    /**
     * @var number
     */
    protected $id;

    /**
     * @var string
     */
    protected $name;

    /**
     * @var Singer
     */
    protected $singer;

    /**
     * @var Album
     */
    protected $album;

    /**
     * @var string
     */
    protected $sourceUrl;

    /**
     * @var string
     */
    protected $playUrl;

    public function __construct($id, $name, $sourceUrl, $playUrl, Singer $singer = null, Album $album = null)
    {
        $this->id = $id;
        $this->name = $name;
        $this->sourceUrl = $sourceUrl;
        $this->playUrl = $playUrl;
        $this->singer = $singer;
        $this->album = $album;
    }

    /**
     * @return number
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * @param number $id
     * @return Song
     */
    public function setId($id)
    {
        $this->id = $id;
        return $this;
    }

    /**
     * @return string
     */
    public function getName()
    {
        return $this->name;
    }

    /**
     * @param string $name
     * @return Song
     */
    public function setName($name)
    {
        $this->name = $name;
        return $this;
    }

    /**
     * @return string
     */
    public function getSourceUrl()
    {
        return $this->sourceUrl;
    }

    /**
     * @param string $sourceUrl
     * @return Song
     */
    public function setSourceUrl($sourceUrl)
    {
        $this->sourceUrl = $sourceUrl;
        return $this;
    }

    /**
     * @return string
     */
    public function getPlayUrl()
    {
        return $this->playUrl;
    }

    /**
     * @param string $playUrl
     * @return Song
     */
    public function setPlayUrl($playUrl)
    {
        $this->playUrl = $playUrl;
        return $this;
    }

    /**
     * @return Singer
     */
    public function getSinger()
    {
        return $this->singer;
    }

    /**
     * @param Singer $singer
     * @return Song
     */
    public function setSinger($singer)
    {
        $this->singer = $singer;
        return $this;
    }

    /**
     * @return Album
     */
    public function getAlbum()
    {
        return $this->album;
    }

    /**
     * @param Album $album
     * @return Song
     */
    public function setAlbum($album)
    {
        $this->album = $album;
        return $this;
    }
}